package org.lhh.server.service;


import org.lhh.server.common.api.JSONResult;
import org.lhh.server.core.codec.database.DatabaseCodec;
import org.lhh.server.pojo.vo.DatabaseNodeVo;
import org.pentaho.di.trans.TransMeta;

import java.util.List;

public interface IDatabaseService {

    void save(DatabaseCodec databaseCodec);

    void test(DatabaseCodec databaseCodec);

    void remove(String name);

    DatabaseCodec getDataBaseById(Long id);

    List<DatabaseNodeVo> explorer(String connection, String nodeId, String tableName);

    List<String> tableFields(String graphXml, String connection, String schema, String table);

    JSONResult getList();

    void copy(DatabaseCodec databaseCodec);

    String getSQL(TransMeta transMeta, String connection, String schema, String table, boolean yes);
}
